<%@ page contentType="text/html; charset=utf-8" language="java" %>
<%@ page isELIgnored="false" %>
<%@ include file="/common/taglibs.jsp"%>
<%@ taglib uri="http://www.shengruan.org/tags" prefix ="f"%> 
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Pragma" content="no-cache">
<link href="../style.css" rel="stylesheet" type="text/css">
<link href="<c:url value='/admin/assets/style/jqueryform.css'/>" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="<c:url value='/admin/assets/js/util.js'/>"></script>
<script type="text/javascript" src="<c:url value='/assets/js/My97DatePicker/WdatePicker.js'/>"></script>
<script type="text/javascript" src="<c:url value='/admin/assets/js/jquery/jquery.js'/>"></script>
<script type="text/javascript" src="<c:url value='/admin/assets/js/jquery/jquery-validate/lib/jquery.metadata.js'/>"></script>
<script type="text/javascript" src="<c:url value='/admin/assets/js/jquery/jquery-validate/jquery.validate.js'/>"></script>
<script type="text/javascript" language="javascript">
// <![CDATA[
$(document).ready(function() {

<c:if test="${not empty requestScope.message}">
$("#infoSpan").html("<img src='<c:url value='/admin/assets/images/flag.gif'/>'><font color='#C00000'><c:out value='${requestScope.message}' escapeXml='false'/></font>");
</c:if>


});
// ]]>
</script>
</head>
<body class="main">
<form method="post" name="orderForm" id="orderForm" action="<c:url value='/admin/order/order-edit.ac'/>" >
<input type="hidden" id="id" name="id" value="${requestScope.orders.id}"/>
<table class="container" cellpadding="0" cellspacing="0">
<tr><td>
<table class="dialog" align="center" cellpadding="0" cellspacing="0" width="929">
<tr><td>
<table class="header" cellpadding="0" cellspacing="0">
<tr>
<td>订单信息</td>
</tr>
</table>
</td></tr>
<tr>
  <td class="body">
<table class="body" cellpadding="0" cellspacing="0">
<tr>
  <td colspan="2" align="center" id="errorTd">&nbsp;<span id="infoSpan" class="infoSpan">&nbsp;</span></td>
  </tr>
  <tr>
  <td width="25%" align="right"><strong>订单编号：</strong></td>
  <td width="75%"><c:out value='${requestScope.orders.orderNumber}'/></td>
 </tr>
<tr>
  <td align="right"><strong>支付方式：</strong></td>
  <td>
<c:choose>        
   <c:when test="${requestScope.orders.payBank == 'directPay'}"><img src="/assets/images/img/alipay_1.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'ICBCB2C'}"><img src="/assets/images/img/ICBC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CMB'}"><img src="/assets/images/img/CMB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CCB'}"><img src="/assets/images/img/CCB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'BOCB2C'}"><img src="/assets/images/img/BOC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'ABC'}"><img src="/assets/images/img/ABC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'COMM'}"><img src="/assets/images/img/COMM_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'SPDB'}"><img src="/assets/images/img/SPDB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'GDB'}"><img src="/assets/images/img/GDB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CITIC'}"><img src="/assets/images/img/CITIC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CEBBANK'}"><img src="/assets/images/img/CEB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CIB'}"><img src="/assets/images/img/CIB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'SDB'}"><img src="/assets/images/img/SDB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CMBC'}"><img src="/assets/images/img/CMBC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'HZCBB2C'}"><img src="/assets/images/img/HZCB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'SHBANK'}"><img src="/assets/images/img/SHBANK_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'NBBANK'}"><img src="/assets/images/img/NBBANK_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'SPABANK'}"><img src="/assets/images/img/SPABANK_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'BJRCB'}"><img src="/assets/images/img/BJRCB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'ICBCBTB'}"><img src="/assets/images/img/ENV_ICBC_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'CCBBTB'}"><img src="/assets/images/img/ENV_CCB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'SPDBB2B'}"><img src="/assets/images/img/ENV_SPDB_OUT.gif" border="0"/></c:when>
   <c:when test="${requestScope.orders.payBank == 'ABCBTB'}"><img src="/assets/images/img/ENV_ABC_OUT.gif" border="0"/></c:when>
</c:choose>        
  </td></tr>
<tr>
  <td align="right"><strong>配送方式：</strong></td>
  <td><c:out value='${requestScope.shipping.name}'/></td>
</tr>
<tr>
  <td align="right"><strong>下单时间：</strong></td>
  <td><c:out value='${f:format(requestScope.orders.creationTime)}'/></td>
</tr>
<c:if test="${requestScope.orders.status == 4}">
<tr>
  <td align="right"><strong>取消时间：</strong></td>
  <td><c:if test="${not empty requestScope.orders.cancelTime}"><c:out value='${f:format(orders.cancelTime)}'/></c:if></td>
</tr>
</c:if>
<tr>
  <td align="right"><strong>订单状态：</strong></td>
  <td>
    	<c:choose>
         <c:when test="${requestScope.orders.status == 0}">等待买家付款</c:when>
         <c:when test="${requestScope.orders.status == 1}">等待卖家发货</c:when>
         <c:when test="${requestScope.orders.status == 2}">等待买家确认收货</c:when>
         <c:when test="${requestScope.orders.status == 3}">交易成功</c:when>
         <c:when test="${requestScope.orders.status == 4}">已取消订单</c:when>
         <c:when test="${requestScope.orders.status == 5}">订单付款失败</c:when>
        </c:choose>
        
   &nbsp;&nbsp;
  	
    <select name="ordersStatus" id="ordersStatus" style="width:200px">
    <c:forEach var="ORDERS_STATUS" items="${requestScope.ORDERS_STATUS_MAP}">
         <c:choose>
             <c:when test="${ORDERS_STATUS.key == requestScope.orders.status}">
               <option value="${ORDERS_STATUS.key}" selected><c:out value='${ORDERS_STATUS.value}'/></option>
              </c:when> 
           <c:otherwise>
              <option value="${ORDERS_STATUS.key}"><c:out value='${ORDERS_STATUS.value}'/></option>
           </c:otherwise>
         </c:choose>
    </c:forEach>
  </select> 
        
        
    </td></tr>
<tr>
  <td align="right"><strong>订单备注：</strong></td>
  <td><c:if test="${empty requestScope.orders.description}">无</c:if><c:out value='${requestScope.orders.description}'/></td>
</tr>
</table>
</td></tr>
<tr><td>
<table class="footer" cellpadding="0" cellspacing="0">
<tr><td>
<input class="button" type="submit" value="确定">&nbsp;&nbsp;<input class="button" type="button" value="返回" onClick="document.location='javascript:history.go(-1)'">
</td></tr>
</table>
</td></tr>
</table>
</td></tr>


<tr><td>
<table class="dialog" align="center" cellpadding="0" cellspacing="0" width="929">
<tr><td>
<table class="header" cellpadding="0" cellspacing="0">
<tr>
<td>收货人信息</td>
</tr>
</table>
</td></tr>
<tr>
  <td class="body">
<table class="body" cellpadding="0" cellspacing="0">
<tr>
  <td colspan="2" align="center" id="errorTd">&nbsp;<span id="infoSpan" class="infoSpan">&nbsp;</span></td>
  </tr>
  <tr>
  <td width="25%" align="right"><strong>收货人姓名：</strong></td>
  <td width="75%"><c:out value='${requestScope.orders.recipientName}'/></td>
 </tr>
 <tr>
  <td align="right"><strong>省份：</strong></td>
  <td><c:out value='${requestScope.orders.province}'/>&nbsp;&nbsp;<c:out value='${requestScope.orders.city}'/>&nbsp;&nbsp;<c:out value='${requestScope.orders.area}'/></td>
</tr>
<tr>
  <td align="right"><strong>地址：</strong></td>
  <td><c:out value='${requestScope.orders.streetAddress}'/></td>
</tr>
<tr>
  <td align="right"><strong>邮编：</strong></td>
  <td><c:out value='${requestScope.orders.zipCode}'/></td>
</tr>
<tr>
  <td align="right"><strong>固定电话：</strong></td>
  <td><c:out value='${requestScope.orders.phoneNumber}'/></td>
</tr>
<tr>
  <td align="right"><strong>手机号码：</strong></td>
  <td><c:out value='${requestScope.orders.mobileNumber}' /></td>
</tr>
<tr>
  <td align="right"><strong>电子邮件：</strong></td>
  <td><c:out value='${requestScope.orders.email}' /></td>
</tr>
</table>
</td></tr>
</table>
</td></tr>



<tr><td>
<table class="dialog" align="center" cellpadding="0" cellspacing="0" width="929">
<tr><td>
<table class="header" cellpadding="0" cellspacing="0">
<tr>
<td>商品清单</td>
</tr>
</table>
</td></tr>
<tr>
  <td class="body">

<table class="list" align="center" cellspacing="1" cellpadding="0">
<tr class="heading">
<td width=27%>商品名称</td>
<td width=6%>官方价格</td>
<td width=6%>封顶价格</td>
<td width=13%>开始竞拍时间</td>
<td width=6%>当前价格</td>
<td width="6%">竞标轮数</td>
<td width=7%>竞拍状态</td>
<td width=3%>状态</td>
</tr>

<c:forEach var="product" items="${requestScope.orderProductList}" varStatus="loop">
<tr <c:if test='${loop.count%2==0}'>class="odd"</c:if>>
  <td height="20" title="<c:out value='${product.name}'/>"><c:out value='${fn:substring(product.name,"0","45")}'/>......</td>
  <td><fmt:formatNumber value="${product.officialPrice}" type="currency" pattern="￥0.00"/></td>
  <td><fmt:formatNumber value="${product.priceCap}" type="currency" pattern="￥0.00"/></td>
  <td><c:out value='${f:format(product.auctionBeginTime)}'/></td>
  <td height="20"><fmt:formatNumber value="${product.currentPrice}" type="currency" pattern="￥0.00"/></td>
  <td><c:out value='${product.bidRound}'/></td>
  <td height="20">
<c:choose>
 <c:when test="${product.auctionStatus == 1}">即将开始</c:when>
 <c:when test="${product.auctionStatus ==2}">竞拍中</c:when>
 <c:when test="${product.auctionStatus ==3}">竞拍结束</c:when>
</c:choose>
  </td>
  <td height="20">

<c:choose><c:when test="${product.isvalid == 0}"><img src="<c:url value='/admin/assets/images/no.png'/>" title="下架" width="16" height="17" border="0" /></c:when><c:otherwise><img src="<c:url value='/admin/assets/images/ok.gif'/>" title="上架" width="16" height="17" border="0" /></c:otherwise></c:choose>



  </td>
</tr>
</c:forEach>
</table>



</td></tr>

</table>
</td></tr>





</table>
</form>

</body>
</html>
